using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Attributes.DomainAttributes;
using Baci.Net.ToolKit.ArcGISProGeoprocessor.Models.Enums;
using System.Collections.Generic;
using System.ComponentModel;

namespace Baci.ArcGIS._DataManagementTools._General
{
    /// <summary>
    /// <para>Rename</para>
    /// <para>Changes the name of a dataset.  This includes a wide variety of data types, among them feature dataset, raster, table, and shapefile.</para>
    /// <para>更改数据集的名称。 这包括多种数据类型，其中包括要素数据集、栅格、表和 shapefile。</para>
    /// </summary>    
    [DisplayName("Rename")]
    public class Rename : AbstractGPProcess
    {
        /// <summary>
        /// 无参构造
        /// </summary>
        public Rename()
        {

        }

        /// <summary>
        /// 有参构造
        /// </summary>
        /// <param name="_in_data">
        /// <para>Input Data Element</para>
        /// <para>The input data to be renamed.</para>
        /// <para>要重命名的输入数据。</para>
        /// </param>
        /// <param name="_out_data">
        /// <para>Output data element</para>
        /// <para>The name for the output data.</para>
        /// <para>输出数据的名称。</para>
        /// </param>
        public Rename(object _in_data, object _out_data)
        {
            this._in_data = _in_data;
            this._out_data = _out_data;
        }
        public override string ToolboxName => "Data Management Tools";

        public override string ToolName => "Rename";

        public override string CallName => "management.Rename";

        public override List<string> AcceptEnvironments => ["scratchWorkspace", "workspace"];

        public override object[] ParameterInfo => [_in_data, _out_data, _data_type];

        /// <summary>
        /// <para>Input Data Element</para>
        /// <para>The input data to be renamed.</para>
        /// <para>要重命名的输入数据。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Input Data Element")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _in_data { get; set; }


        /// <summary>
        /// <para>Output data element</para>
        /// <para>The name for the output data.</para>
        /// <para>输出数据的名称。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Output data element")]
        [Description("")]
        [Option(OptionTypeEnum.Must)]
        public object _out_data { get; set; }


        /// <summary>
        /// <para>Data type</para>
        /// <para>The type of data to be renamed. The only time you need to provide a value is when a geodatabase contains a feature dataset and a feature class with the same name. In this case, you need to select the data type (feature dataset or feature class) of the item you want to rename.</para>
        /// <para>要重命名的数据类型。只有当地理数据库包含要素数据集和同名要素类时，才需要提供值。在这种情况下，您需要选择要重命名的项目的数据类型（要素数据集或要素类）。</para>
        /// <para></para>
        /// </summary>
        [DisplayName("Data type")]
        [Description("")]
        [Option(OptionTypeEnum.optional)]
        public object _data_type { get; set; } = null;


        public Rename SetEnv(object scratchWorkspace = null, object workspace = null)
        {
            base.SetEnv(scratchWorkspace: scratchWorkspace, workspace: workspace);
            return this;
        }

    }

}